Prepared by
- Ahmed Abdelaziz - 120200139
- Mohamed Kamal - 120200137
- Bassem Gabr Ali - 120210142
A PostgreSQL function to quickly identify Mirth channels where the Source Connector is taking a long time to process messages. It aggregates statistics and lists specific Message IDs for easy troubleshooting.
Run this once to create the function in your Mirth database.
CREATE OR REPLACE FUNCTION check_slow_channels(
threshold_seconds INT DEFAULT 15, Update all outdated dependencies in this Elixir project, handling both safe updates and breaking changes.
Run mix hex.outdated to get a list of all outdated dependencies. Parse the output to identify:
| # Docker compose to set up containers for all services you need: | |
| # VPN | |
| # Sonarr, Radarr, Lidarr, Qbittorrent | |
| # Non-VPN | |
| # Plex, get_iplayer | |
| # Before running docker-compose, you should pre-create all of the following folders. | |
| # Folders for Docker State: | |
| # /volume1/dockerdata. - root where this docker-compose.yml should live | |
| # /volume1/dockerdata/plex - Plex config and DB | |
| # /volume1/dockerdata/sonarr - Sonarr config and DB |
| WITH | |
| -- 1. EXTRACT CONFIGURATION | |
| CHANNEL_CONFIG AS ( | |
| SELECT | |
| (XPATH('/entry/string/text()', ENTRY))[1]::TEXT AS CID | |
| , (XPATH('/entry/*[2]/enabled/text()', ENTRY))[1]::TEXT::BOOLEAN AS CHANNEL_ENABLED | |
| , (XPATH('/entry/*[2]/pruningSettings/archiveEnabled/text()', ENTRY))[1]::TEXT::BOOLEAN AS ARCHIVE_ENABLED | |
| , (XPATH('/entry/*[2]/pruningSettings/pruneErroredMessages/text()', ENTRY))[1]::TEXT::BOOLEAN AS PRUNE_ERROR_MESSAGES | |
| , COALESCE((XPATH('/entry/*[2]/pruningSettings/pruneMetaDataDays/text()', ENTRY))[1]::TEXT::INT, -1) AS PRUNE_DAYS | |
| FROM ( |
| # Helpful information: | |
| # https://github.com/Excodibur/ioBroker.schwoerer-ventcube/blob/master/src/lib/schwoerer/parameters.ts | |
| # https://github.com/fgoettel/wgt/blob/main/wgt/lueftungsanlage.py | |
| # https://knx-user-forum.de/forum/öffentlicher-bereich/knx-eib-forum/diy-do-it-yourself/1822296-modbus-schwörer-heizung?p=1906252#post1906252 | |
| ################## | |
| # MODBUS SENSORS # | |
| ################## | |
| modbus: |
| import sys | |
| import argparse | |
| import threading | |
| import json | |
| import time | |
| from http.server import SimpleHTTPRequestHandler, HTTPServer | |
| from urllib.parse import urlencode, quote | |
| import websocket # pip install websocket-client |
You are Grok 4 built by xAI.
When applicable, you have some additional tools:
In case the user asks about xAI's products, here is some information and response guidelines:
| #!/bin/bash | |
| # | |
| # script to fully prepare ImageNet dataset | |
| ## 1. Download the data | |
| # get ILSVRC2012_img_val.tar (about 6.3 GB). MD5: 29b22e2961454d5413ddabcf34fc5622 | |
| # wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_img_val.tar | |
| # get ILSVRC2012_img_train.tar (about 138 GB). MD5: 1d675b47d978889d74fa0da5fadfb00e | |
| # wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_img_train.tar |